package com.example.everying.mapper.content;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.everying.model.entity.content.ActivityApply;
import com.example.everying.model.vo.content.ActivityApplyVo;
import com.example.everying.model.vo.content.ApplyViewVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface ActivityApplyMapper extends BaseMapper<ActivityApply> {
    List<ActivityApplyVo> applyList(String artId);
    ActivityApply  getApplyById(String artId);

    ActivityApply getArticleById(String artId,String userId);

    /**
     * 根据申请人的结束时间修改文章状态
     */
    void updateStatus();

    List<ActivityApplyVo> selectArtId(@Param("artId") String artId,String userId);

    List<ApplyViewVo> selectBatchArtId(@Param("artIds") List<String> artIds,String ordersStatus);

    int isFirstApply(String applyUserId);
}
